import { lazy } from "react";
const BankList = lazy(() =>
	import("@views/viewCommon/bank/bankList/wallet.jsx")
);
const AddBank = lazy(() => import("@views/viewCommon/bank/addBank/index"));
const Liveness = lazy(() => import("@views/viewCommon/liveness/index"));
const EditPersonalInfo = lazy(() =>
	import("@views/viewCommon/editPersonalInfo/index")
);
const InitSdk = lazy(() => import("@views/initSdk/index"));
const OpenAccountResult = lazy(() =>
	import("@views/viewCommon/openAccountResult/index")
);
const uploadIDCardImgPage = lazy(() =>
	import("@views/viewCommon/uploadIDCard/UploadIDCardImg")
);
const PersonalCreditAuthorization = lazy(() =>
	import("@views/agreement/PersonalCreditAuthorization")
);
const PersonalInformationLicense = lazy(() =>
	import("@views/agreement/PersonalInformationLicense")
);
const MyProtocolListPage = lazy(() =>
	import("@views/viewCommon/myProtocolList/MyProtocolList")
);
const setPayPwdPage = lazy(() =>
	import("@views/viewCommon/setPayPassword/SetPayPassword")
);
const PersonalCreditAmountPage = lazy(() =>
	import("@views/agreement/PersonalCreditAmountContract")
);
const XhfXy = lazy(() => import("@views/agreement/UserServicesAgreementPage"));
const Individualloancontract = lazy(() =>
	import("@views/agreement/Individualloancontract")
);
const agreementoflianyintong = lazy(() =>
	import("@views/agreement/agreementoflianyintong")
);
const Exclusiveproductagreement1A = lazy(() =>
	import("@views/agreement/Exclusiveproductagreement1A")
);
const Exclusiveproductagreement1B = lazy(() =>
	import("@views/agreement/Exclusiveproductagreement1B")
);
const EditContactInfo = lazy(() =>
	import("@views/viewCommon/editContactInfo/index")
);
const RepaymentMoneyPage = lazy(() =>
	import("@views/viewCommon/repayment/RepaymentMoney")
);
const RepaymentSuccessPage = lazy(() =>
	import("@views/viewCommon/repayment/RepaymentSuccess")
);
const AuthenticatePayPage = lazy(() =>
	import("@views/viewCommon/repayment/authenticate/AuthenticatePay")
);
const BackPay = lazy(() =>
	import("@views/viewCommon/repayment/authenticate/BackPay")
);
const PayRetPage = lazy(() =>
	import("@views/viewCommon/repayment/authenticate/PayRet")
);
const xhfPayRetPage = lazy(() =>
	import("@views/viewCommon/repayment/authenticate/xhfPayRet")
);
const FaceAgreement = lazy(() => import("@views/agreement/FaceAgreement"));
const PayFail = lazy(() => import("@views/viewCommon/paymentresult/PayFail"));
const PaySuccess = lazy(() =>
	import("@views/viewCommon/paymentresult/PaySuccess")
);
const HTPayServiceAgreement = lazy(() =>
	import("@views/agreement/HTPayServiceAgreement")
);
const ServiceAgreementAuthorization = lazy(() =>
	import("@views/agreement/ServiceAgreementAuthorization")
);
const IndividualloancontractB = lazy(() =>
	import("@views/agreement/IndividualloancontractB")
);
const PayCode = lazy(() => import("@views/viewCommon/payCode"));
const XhfLivenessRet = lazy(() =>
	import("@views/viewCommon/liveness/xhfLivenessRet")
);
const IframePage = lazy(() => import("@views/viewCommon/iframe/iframe"));

const iframeAgreements = lazy(() =>
	import("@views/viewCommon/iframeAgreements/iframeAgreements")
);
const selectCoupon = lazy(() =>
	import("@views/viewCommon/selectCoupon/selectCoupon")
);
const NonStudentCommitmentLetter = lazy(() =>
	import("@views/agreement/NonStudentCommitmentLetter")
);
/**支付宝还款结果 */
const xhfAlipayRetPage = lazy(() =>
	import("@views/viewCommon/repayment/authenticate/AlipayRepaymentRet")
);

/**银行卡管理*/
const BankManageList = lazy(() =>
	import("@views/viewCommon/bankManage/bankList/index")
);
const BankManageAdd = lazy(() =>
	import("@views/viewCommon/bankManage/AddBank/index")
);
const BankManageInfo = lazy(() =>
	import("@views/viewCommon/bankManage/bankInfo/index")
);
const UnBindBank = lazy(() =>
	import("@views/viewCommon/bankManage/unBindBank/index")
);
const bindBankAdv = lazy(() => import("@/views/viewCommon/bank/addBankAdv"));

const AllQuestion = lazy(() => import("@views/viewCommon/allQuestion/index")); //全平台常见问题

// 页面加载失败
const error404 = lazy(() => import("@views/error404/error404")); // 404

const sSecurityIndex = lazy(() => import("@views/advertising/sSecurity/index")); // 山西证券

const couponSending = lazy(() => import("@views/viewCommon/couponSending")); // 优惠券派发中

let commonRoutes = [
	{
		pathName: "/xhfLivenessRet",
		component: XhfLivenessRet,
		exact: false
	},

	{
		pathName: "/backPay",
		component: BackPay,
		exact: false
		// cacheRouter: true,
		// cacheKey: 'backPay',
	},
	{
		pathName: "/payRet",
		component: PayRetPage,
		exact: false
	},
	{
		pathName: "/xhfPayRet",
		component: xhfPayRetPage,
		exact: false
	},
	{
		pathName: "/xhfAlipayRet",
		component: xhfAlipayRetPage,
		exact: false
	},
	{
		pathName: "/repaymentMoney/:data",
		component: RepaymentMoneyPage,
		exact: false
	},
	{
		pathName: "/repaymentSuccess",
		component: RepaymentSuccessPage,
		exact: false
	},
	{
		pathName: "/authenticatePay/:data",
		component: AuthenticatePayPage,
		exact: false
	},
	{
		pathName: "/bankList",
		component: BankList,
		exact: false
	},
	{
		pathName: "/addBank",
		component: AddBank,
		exact: false,
		cacheRouter: true,
		cacheKey: "AddBank"
	},
	{
		pathName: "/liveness/:data",
		component: Liveness,
		exact: false
	},
	{
		pathName: "/editPersonalInfo",
		component: EditPersonalInfo,
		exact: false,
		cacheRouter: true,
		cacheKey: "editPersonalInfo"
	},
	{
		pathName: "/initSdk",
		component: InitSdk,
		exact: false
	},
	{
		pathName: "/openAccountResult",
		component: OpenAccountResult,
		exact: false
		// cacheRouter: true,
		// cacheKey: 'openAccountResult',
	},
	{
		pathName: "/uploadIDCardImgPage",
		component: uploadIDCardImgPage,
		exact: false,
		cacheRouter: true
	},

	{
		pathName: "/myProtocolList",
		component: MyProtocolListPage,
		exact: false
	},
	{
		pathName: "/setPayPwd",
		component: setPayPwdPage,
		exact: false
	},

	{
		pathName: "/editContactInfo",
		component: EditContactInfo,
		exact: false,
		cacheRouter: true
	},
	/* 个人信息授权书 */
	{
		pathName: "/personalInformationLicense",
		component: PersonalInformationLicense,
		exact: false
	},
	/* 个人循环额度贷款合同 */
	{
		pathName: "/personalCreditAmountContract",
		component: PersonalCreditAmountPage,
		exact: false
	},
	/* 个人征信授权书 */
	{
		pathName: "/personalCreditAuthorization",
		component: PersonalCreditAuthorization,
		exact: false
	},
	/* 非在校学生身份承诺函 */
	{
		pathName: "/nonStudentCommitmentLetter",
		component: NonStudentCommitmentLetter,
		exact: false
	},
	/* 隐私政策协议 */
	{
		pathName: "/xhfXy", //此路由不用，换为cdn的隐私协议
		component: XhfXy,
		exact: false
	},
	/* 个人借款合同 */
	{
		pathName: "/Individualloancontract",
		component: Individualloancontract,
		exact: false
	},
	/* 人脸识别协议 */
	{
		pathName: "/faceAgreement",
		component: FaceAgreement,
		exact: false
	},
	/* 连连银通银行卡支付服务协议 */
	{
		pathName: "/agreementoflianyintong",
		component: agreementoflianyintong,
		exact: false
	},
	/* 小辉宝专享产品协议书1A */
	{
		pathName: "/Exclusiveproductagreement1A",
		component: Exclusiveproductagreement1A,
		exact: false
	},
	/* 小辉宝专享产品协议书1B */
	{
		pathName: "/Exclusiveproductagreement1B",
		component: Exclusiveproductagreement1B,
		exact: false
	},
	/* 支付失败 */
	{
		pathName: "/PayFail",
		component: PayFail,
		exact: false
	},
	/* 支付成功 */
	{
		pathName: "/PaySuccess",
		component: PaySuccess,
		exact: false
	},
	/* 个人客户账户消费支付服务协议 */
	{
		pathName: "/HTPayServiceAgreement",
		component: HTPayServiceAgreement,
		exact: false
	},
	/* 永辉金融用户协议 */
	{
		pathName: "/ServiceAgreementAuthorization",
		component: ServiceAgreementAuthorization,
		exact: false
	},
	/* 个人借款合同B */

	{
		pathName: "/IndividualloancontractB",
		component: IndividualloancontractB,
		exact: false
	},
	/* 支付码 */

	{
		pathName: "/payCode",
		component: PayCode,
		exact: false
	},
	{
		pathName: "/iframePage",
		component: IframePage,
		exact: false
	},
	{
		pathName: "/iframeAgreements",
		component: iframeAgreements,
		exact: false
	},
	{
		pathName: "/selectCoupon",
		component: selectCoupon,
		exact: false
	},
	{
		pathName: "/bankManageList",
		component: BankManageList,
		exact: false
	},
	{
		pathName: "/bankManageAdd",
		component: BankManageAdd,
		exact: false,
		cacheRouter: true
	},
	{
		pathName: "/bankManageInfo",
		component: BankManageInfo,
		exact: false
	},
	{
		pathName: "/unBindBank",
		component: UnBindBank,
		exact: false
	},
	{
		pathName: "/bindBankAdv",
		component: bindBankAdv,
		exact: false
	},
	{
		pathName: "/allQuestion",
		component: AllQuestion,
		exact: false
	},
	{
		pathName: "/error404",
		component: error404,
		exact: false
	},
	{
		pathName: "/advertising/sSecurity/index",
		component: sSecurityIndex,
		exact: false
	},
	{
		pathName: "/couponSending",
		component: couponSending,
		exact: false
	}
];

export { commonRoutes };
